package com.ql.dao;

import com.ql.domain.Permission;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface PermissionDao {
    /**
     * 根据userId查询出对应的权限
     *
     * @param userId
     * @return
     */
    @Select("select * from permission where id in (select permissionId from users_permission where userId=#{userId})")
    List<Permission> findByUserId(String userId);
}
